package c.c.a;

import android.content.Context;
import android.content.SharedPreferences;
import android.content.SharedPreferences.Editor;
import java.util.UUID;
import org.json.JSONObject;

public class e2 extends b2 {
    public final Context e;

    public e2(Context context) {
        super(false, false);
        this.e = context;
    }

    public boolean b(JSONObject jSONObject) {
        SharedPreferences sharedPreferences = this.e.getSharedPreferences("snssdk_openudid", 0);
        String str = "clientudid";
        Object string = sharedPreferences.getString(str, null);
        if (!c.g(string)) {
            try {
                string = a("clientudid.dat", UUID.randomUUID().toString());
            } catch (Exception unused) {
            }
            Editor edit = sharedPreferences.edit();
            edit.putString(str, string);
            edit.apply();
        }
        jSONObject.put(str, string);
        return true;
    }
}
